class Solution {
public:
    int finalValueAfterOperations(vector<string>& operations) {
        int ret = 0;
        for (auto& st : operations) {
            if (st[1] == '+') ret++;
            else ret--;
        }
        return ret;
    }
};